﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace FreesqlSimpleExtension.Test
{
    /// <summary>
    /// 测试查询输入实体
    /// </summary>
    public class TestQueryInput
    {
        public int? Id { get; set; }

        [FsContains]
        public string Name { get; set; }

        [FsArrayContains(nameof(TestEntity.Name))]
        public List<string> NameArray { get; set; }

        [FsEq]
        public int? AgeEq { get; set; }

        [FsArrayContains(nameof(TestEntity.Age))]
        public List<int> AgeArray { get; set; }

        [FsGte(nameof(TestEntity.Age))]
        public int? AgeGte { get; set; }
        [FsLte(nameof(TestEntity.Age))]
        public int? AgeLte { get; set; }

        [FsOrderBy(nameof(TestEntity.Age))]
        public List<string> OrderBy { get; set; } = [nameof(TestEntity.Age)];

        [FsDateEq]
        public DateTime? CreateTime { get; set; }

        [FsRange("CreateTime","[]")]
        public List<DateTime> TimeRange { get; set; }

        [FsNull("Name",true)]
        public string NameNull { get; set; }

        [FsNotNull("Age")]
        public string AgeNotNull { get; set; }
    }
}
